<?php

class GoodsProviderValidator extends CValidator {
	/* (non-PHPdoc)
	 * @see CValidator::validateAttribute()
	 */
	protected function validateAttribute($object, $attribute) {
		if($object->class_id != CHtml::value($object, 'provider.info.category_id')) {
			$object->addError('provider_id', '供应类型不符！');
		}
	}


}



?>